home *** CD-ROM | disk | FTP | other *** search
/ MacHack 1997 / MacHack 1997.toast / Hacks / Hacks ’97 / Warrior’s Progress / source code / Source / Libraries / Announcer / Announcer.cp next >
Encoding:
Text File  |  1997-06-28  |  633 b   |  38 lines  |  [TEXT/CWIE]

  1. // Announcer.cp
  2.  
  3. #ifndef Announcer_h
  4. #include "Announcer.h"
  5. #endif
  6. #ifndef EarBase_h
  7. #include "EarBase.h"
  8. #endif
  9. #ifndef ListLoop_h
  10. #include "ListLoop.h"
  11. #endif
  12. #ifndef ContextMaintainer_h
  13. #include "ContextMaintainer.h"
  14. #endif
  15.  
  16. Announcer::Announcer()
  17.   {
  18.   }
  19.  
  20. Announcer::~Announcer()
  21.   {
  22.     ContextMaintainer    oldContext;
  23.     for ( ListLoop<EarBase> ear(ears); ear.Unfinished(); ear++ )
  24.         ear->HearDestruction();
  25.     
  26.     ears.RemoveAll();
  27.   }
  28.  
  29. void Announcer::Announce()
  30.   {
  31.     ContextMaintainer    oldContext;
  32.     for ( ListLoop<EarBase> ear(ears); ear.Unfinished(); ear++ )
  33.         ear->HearAnnouncement();
  34.   }
  35.  
  36. #include "ListLoop.cp"
  37. #include "ListOf.cp"
  38.